#ifndef CCSTREAMSERVERDEF_H
#define CCSTREAMSERVERDEF_H
#include <iostream>
#include <stdio.h>
#include <atomic>
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include <sys/types.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <sys/wait.h>
#include <sys/stat.h>
#include <unistd.h>
#include <arpa/inet.h>
#include <fcntl.h>
#include <err.h>
#include <netdb.h>
#include <sys/ioctl.h>
#include <net/if.h>
#include <pthread.h>
#include <time.h>
#include <signal.h>
#include <sys/select.h>
#include <sys/ioctl.h>
#include <net/if.h>
#include <string.h>
#include <netinet/in.h>
#include <ifaddrs.h>
#include <errno.h>
#include <netdb.h>
#include <stdbool.h>
#include <alsa/asoundlib.h>
#include <signal.h>
#include <vector>
#define LISTEN_POT 30000

#define MSGHEADER_TYPE_KEEPALIVE    0
#define MSGHEADER_TYPE_AVSTREAM 1

#define CONTEXT_AVSTREAM_VIDEO 3
#define CONTEXT_AVSTREAM_AUDIO 4 

#pragma pack(push,1) //一字节对齐，默认三四字节对齐

typedef struct netMessageHeader{
    uint8_t headrID[4];
    uint16_t msgType;
    uint16_t subType;
    uint32_t contentLength;
}CC_MsgHeader;


typedef struct netAVStream
{
    uint8_t* buffer;
    uint32_t size;
    uint16_t type;
}CC_AVStream;


#pragma pack(pop)















#endif